package ch.xch.ehadaily.base;

import android.os.AsyncTask;
import android.os.Build;

/**
 * Created by XCH on 2014/10/31.
 */
public abstract class BaseTask<Params, Progress, Result> extends AsyncTask<Params, Progress, Result> {
    public void forceExceute() {
        forceExcecute(null);
    }

    public void forceExcecute(Params... params) {
        if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB) {
            executeOnExecutor(THREAD_POOL_EXECUTOR, params);
        } else {
            execute(params);
        }
    }

}
